package com.design.model.builder;

import java.util.ArrayList;
import java.util.List;

/**
 * @program: study
 * @className: Product
 * @description: TODO
 * @author: kukuxiahuni
 * @create: 2019-07-11 11:13
 * @version: v1.0
 **/
public class Product {

    private final List<String> parts = new ArrayList<>();

    /**
     * 功能描述: TODO
     *
     * @param:
     * @return:
     * @auther: kukuxiahuni
     * @date: 2019/7/11 11:14 AM
     * @modify_auther: kukuxiahuni
     * @modify_time: 2019/7/11 11:14 AM
     **/
    public void add(String part) {
        this.parts.add(part);
    }

    /**
     * 功能描述: TODO
     *
     * @param:
     * @return:
     * @auther: kukuxiahuni
     * @date: 2019/7/11 11:14 AM
     * @modify_auther: kukuxiahuni
     * @modify_time: 2019/7/11 11:14 AM
     **/
    public void show() {
        parts.forEach(
                e -> System.out.println(e)
        );
    }
}
